# -*- coding:utf-8 -*-
__author__ = 'maruimin'

from django.conf.urls import url

from courses.views import CourseListView, CourseDetailView, CourseInfoView, CommentsView, AddCommentsView, VideoPlayView


urlpatterns = [
    url(r'^list/$', CourseListView.as_view(), name='course_list'),
    url(r'^detail/(?P<course_id>\d+)/$', CourseDetailView.as_view(), name='course_detail'),
    url(r'^info/(?P<course_id>\d+)/$', CourseInfoView.as_view(), name='course_info'),   # 课程章节详情页面
    url(r'^comment/(?P<course_id>\d+)/$', CommentsView.as_view(), name='course_comments'),   # 课程评论详情页面
    url(r'^add_comment/', AddCommentsView.as_view(), name='add_comment'),   # 用户添加课程评论
    url(r'^video/(?P<video_id>\d+)/$', VideoPlayView.as_view(), name='video_play'),
]